<template>
	  <div class="product-box">
      <Banner/>
      <div class="content">
        <ul class="nav">
          <li :class="{bg1:index == id}" @click="getId(index)" v-for="item,index in $t('page.index.product.pList')" :key="index">{{ item.title }}</li>
        </ul>
        <tab :idx='id'/>
        <div class="item item3">
          <h3>{{ $t('page.product.itemCommon.title') }}</h3>
          <hr>
          <div class="advantage" >
            <div class="block" v-for="item,index in $t('page.product.itemCommon.iList')" :key="index">
              <img :src="item.imgUrl" alt="">
              <h5>{{ item.title }}</h5>
            </div>
          </div>
        </div>
      </div>
    </div>
</template>  
  
<script>
import Banner from "@/components/Index/Banner";
import Tab from "@/components/Tab";

export default {
  data() {
    return {
      id: 0
    };
  },
  methods: {
    getId(index) {
      this.id = index;
    }
  },
  mounted() {
    let obj = this.$router.history.current.params
    if (obj.userId) {
      this.id = obj.userId;
    }
  },
  components: {
    Banner,
    Tab
  }
};
</script>  
<style>
.product-box .content {
  width: 1200px;
  margin: 0 auto 209px;
  font-size: 16px;
}
.product-box .nav {
  display: -ms-flexbox;
  display: flex;
  background-color: #ebebec;
}
.product-box .nav li {
  height: 50px;
  line-height: 50px;
  -ms-flex: 1;
  flex: 1;
  font-size: 12px;
  cursor: pointer;
}
.product-box .nav li.bg1 {
  background-color: #4b96ff;
  color: #fff;
}
.product-box h2 {
  margin: 50px 0 30px;
  font-size: 30px;
}
.product-box .item {
  margin-bottom: 30px;
}
.product-box .item2 h3 {
  margin-bottom: 47px;
}
.product-box .item3 h3 {
  margin-bottom: 47px;
}
.product-box hr {
  background-color: #dee3e7;
  height: 1px;
  margin: 20px 0;
  border-top: 0;
}
.product-box h3 {
  padding-left: 10px;
  font-size: 16px;
  border-left: 2px solid #4b96ff;
  text-align: left;
}
.product-box h4 {
  text-align: left;
  font-size: 14px;
}
.product-box .item-content {
  text-align: left;
  font-size: 14px;
  line-height: 26px;
}
.product-box .item3 .advantage {
  display: -ms-flexbox;
  display: flex;
  -ms-flex-pack: justify;
  justify-content: space-between;
}
.product-box .item3 .advantage .block {
  width: 170px;
  height: 170px;
}
.product-box .item3 .advantage h5 {
  font-size: 20px;
  line-height: 25px;
  margin-top: 16px;
}
</style> 